All Questions
Tagged with javaobject-oriented
727 questions
0votes
3answers
175views
Java exceptions that show the message when converted to String
I’m working with custom exceptions in Java for stack operations. However, I’m unsure if the exception handling is being handled properly, especially in terms of how exceptions are thrown and caught. ...
0votes
1answer
62views
Bulk conditions evaluation throwing a single RuntimeException exception
Bulk conditions evaluation throwing a single exception of a configurable type for all unfulfilled conditions. It is developed around several design patterns: (1) fluent interface to configure the ...
3votes
1answer
215views
Simulate an Automated Teller Machine (ATM)
(Game: ATM machine) Use the Account class created in Programming Exercise 9.7 to simulate an ATM machine. Create ten accounts in an array with id 0, 1, . . . , 9, and initial balance $100. The system ...
6votes
3answers
469views
First Java Program: A Basic GUI Library Management System with JavaFX
Requirements: Add/Delete member. Add/Delete book. Issue/Return book. Review Request: General coding comments, bad practices, style et cetera. Code: Main.java: <...
3votes
1answer
123views
Amount Transfer Between Different Accounts - Improved Version
This is an improved code version for Amount Transfer Between Different Accounts Welcoming any further improvements for this. ...
4votes
1answer
104views
Sequentially bidirectional find the indexes of an element into a collection (after second thought)
The util class to find all the indexes on an element into a Collection supports forward and reverse lookup starting from a given index along with changing the ...
4votes
1answer
216views
Amount Transfer Between Different Accounts
I implemented the below classes for transfer amount between different accounts. Used ConcurrentHashMap and Stamped Lock to handle concurrency. Am I missing any important concepts here? Are there any ...
6votes
2answers
876views
Reduce String Length With Thread Safety & Concurrency
I implemented the below URL Shortener class. Used ConcurrentHashMap to handle concurrency. Short URL building logic may not be optimal, but it ensures that only ...
2votes
0answers
71views
Classes for Config and logical operators
I have a spring cloud gateway application with this yml structure for request validation: ...
3votes
1answer
229views
A library management system
Following is my code for a library management system. I am pretty new to OOD and trying to learn it. I am specially looking for ways where any design patterns can be useful here. I tried to make ...
1vote
2answers
105views
simple Text Table utility
A small utility to print data in an ascii table TextTable ...
5votes
2answers
290views
2048 game in Java
I am a beginner learning Java, and I coded a command line version of the game 2048 for practice. Any feedback, especially regarding best practices, object-oriented principles, and tidying up the code ...
2votes
2answers
97views
Java Queue data structure
Could you review this implementation of a queue data structure according to the principles of Object Oriented Programming and Clean Code? ...
2votes
3answers
234views
Java Clean Code, use of enums in data structure
I have defined a data structure in Java that allows to manage certain type of elements like a Queue, with the special feature of using 2 inner rows (windows) to attend elements: ...
-1votes
1answer
69views
Object build while sequential read user input [closed]
The implementation reads sequentially the user's input changing the type to build according to user choices. There are two main components a conditional structural sharing (...